<?xml version="1.0"?>
<project
	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
	xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
	<modelVersion>4.0.0</modelVersion>


  <parent>
    <groupId>br.com.membros</groupId>
    <artifactId>membros-all</artifactId>
    <version>0.0.1-SNAPSHOT</version>
  </parent>
	

  <artifactId>membros-factory</artifactId>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<main.class>br.com.membros.factory.MembrosMain</main.class>
	</properties>
  
<dependencies>

		<!-- Membros business -->
		<dependency>
			<groupId>${project.groupId}</groupId>
			<artifactId>membros-business</artifactId>
		</dependency>
    
			<!-- Membros database -->
		<dependency>
			<groupId>${project.groupId}</groupId>
			<artifactId>membros-database</artifactId>
		</dependency>
		
		
				<!-- Membros service -->
		<dependency>
			<groupId>${project.groupId}</groupId>
			<artifactId>membros-service</artifactId>
		</dependency>
			
		
    
    		<!-- Membros Utils -->
		<dependency>
			<groupId>${project.groupId}</groupId>
			<artifactId>membros-utils</artifactId>
		</dependency>
	</dependencies>
<build>
		<resources>
			<resource>
				<directory>src/main/resources</directory>
				<includes>
					<include>**/*.xml</include>
				</includes>
				<filtering>true</filtering>
			</resource>
		</resources>

		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-shade-plugin</artifactId>
				<executions>
					<execution>
						<phase>package</phase>
						<goals>
							<goal>shade</goal>
						</goals>
						<configuration>
							<shadedArtifactAttached>true</shadedArtifactAttached>
							<shadedClassifierName>membros</shadedClassifierName>
							<shadedArtifactId>membros</shadedArtifactId>
						</configuration>
					</execution>
				</executions>
				<configuration>
					<finalName>membros-server-${version}</finalName>
					<transformers>
						<transformer
							implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
							<resource>META-INF/spring.handlers</resource>
						</transformer>
						<transformer
							implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
							<resource>META-INF/spring.schemas</resource>
						</transformer>
						<transformer
							implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
							<manifestEntries>
								<Main-Class>${main.class}</Main-Class>
							</manifestEntries>
						</transformer>
					</transformers>
				</configuration>
			</plugin>
		</plugins>
	</build>
</project>
